package cn.kgc.client;

import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.Map;

/**
 * @Author: 课工场
 * @Version: v1.0  2023/4/23
 * @Description:
 */
@Component
public class HystrixClientFallback implements HystrixClient {

    @Override
    public Map<String, Object> method1(Integer id) {
        HashMap<String, Object> map = new HashMap<>();
        map.put("code", 500);
        map.put("msg", "网络异常,请稍后再试！！！");
        map.put("data", id);
        return map;
    }
}
